{
	"info": {
		"_postman_id": "6c989e91-e066-4bee-b877-e775cea54f2b",
		"name": "Протокол 1.3 Физиотерапия",
		"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
		"_exporter_id": "48020210",
		"_collection_link": "https://nst-sid-6186244.postman.co/workspace/nst-sid's-Workspace~d2a1dc8f-cae0-4166-807b-dc131f8f29a6/collection/48020210-6c989e91-e066-4bee-b877-e775cea54f2b?action=share&source=collection_link&creator=48020210"
	},
	"item": [
		{
			"name": "Предварительные условия",
			"item": [
				{
					"name": "Достать врача и организацию из токена врача и добавить в переменную",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"const jwt = pm.request.auth.oauth2.get(\"accessToken\");\r",
									"console.log(jwt);\r",
									"if (jwt) {\r",
									"    let payload = jwt.split('.')[1];\r",
									"    payload = payload.replace(/-/g, '+').replace(/_/g, '/');\r",
									"    while (payload.length % 4) payload += '=';\r",
									"    let decoded = JSON.parse(atob(payload));\r",
									"    console.log(decoded)\r",
									"    let practitionerId = decoded.practitioner_id || decoded.practitionerId || decoded[\"practitioner_id\"];\r",
									"    let organizationId = decoded.organization_id || decoded.organizationId || decoded[\"organization_id\"];\r",
									"    if (practitionerId) pm.environment.set(\"PractitionerId\", practitionerId);\r",
									"    if (organizationId) pm.environment.set(\"OrganizationId\", organizationId);\r",
									"} else {\r",
									"    console.log(\"JWT токен не найден в переменных коллекции\");\r",
									"}"
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"protocolProfileBehavior": {
						"disableBodyPruning": true
					},
					"request": {
						"method": "GET",
						"header": [
							{
								"key": "X-Fhir-By-Version",
								"value": "0.3.4934",
								"type": "text"
							}
						],
						"body": {
							"mode": "raw",
							"raw": ""
						},
						"url": {
							"raw": "https://postman-echo.com/get",
							"protocol": "https",
							"host": [
								"postman-echo",
								"com"
							],
							"path": [
								"get"
							]
						}
					},
					"response": []
				},
				{
					"name": "Достать PractitionerRole врача (PractitionerRole)",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"var jsonData = pm.response.json();\r",
									"let practitionerRole = jsonData.entry.find(obj => obj.resource.resourceType === \"PractitionerRole\").resource.id;\r",
									"\r",
									"pm.environment.set(\"PractitionerRole\", practitionerRole);\r",
									"console.log(practitionerRole)\r",
									""
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/PractitionerRole?practitioner={{PractitionerId}}",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"PractitionerRole"
							],
							"query": [
								{
									"key": "practitioner",
									"value": "{{PractitionerId}}"
								}
							]
						}
					},
					"response": []
				},
				{
					"name": "Достать структурное подразделение врача (LocationId)",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"let json = pm.response.json();\r",
									"let locationValue = null;\r",
									"\r",
									"if (Array.isArray(json.entry)) {\r",
									"    for (let entry of json.entry) {\r",
									"        if (\r",
									"            entry.resource &&\r",
									"            entry.resource.resourceType === \"PractitionerRole\" &&\r",
									"            Array.isArray(entry.resource.location) &&\r",
									"            entry.resource.location.length > 0\r",
									"        ) {\r",
									"            // Берём reference первого location и извлекаем только UUID\r",
									"            let ref = entry.resource.location[0].reference;\r",
									"            if (typeof ref === \"string\" && ref.startsWith(\"Location/\")) {\r",
									"                locationValue = ref.split(\"/\")[1]; // или: ref.replace(\"Location/\", \"\")\r",
									"            }\r",
									"            break;\r",
									"        }\r",
									"    }\r",
									"}\r",
									"\r",
									"if (locationValue) {\r",
									"    pm.environment.set(\"LocationId\", locationValue);\r",
									"    console.log(\"location сохранён:\", locationValue);\r",
									"} else {\r",
									"    console.log(\"location не найден\");\r",
									"}\r",
									""
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/PractitionerRole?_id={{PractitionerRole}}",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"PractitionerRole"
							],
							"query": [
								{
									"key": "_id",
									"value": "{{PractitionerRole}}"
								}
							]
						}
					},
					"response": []
				}
			]
		},
		{
			"name": "1. Назначение курсов физиопроцедур двух видов",
			"item": [
				{
					"name": "Поиск пациента по идентификатору (patientId)",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"var jsonData = pm.response.json();\r",
									"let patientId = jsonData.entry.find(obj => obj.resource.resourceType === \"Patient\").resource.id;\r",
									"\r",
									"pm.environment.set(\"patientId\", patientId);\r",
									"console.log(patientId)\r",
									""
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Patient?identifier=7551355A009PB4",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Patient"
							],
							"query": [
								{
									"key": "identifier",
									"value": "7551355A009PB4"
								}
							]
						}
					},
					"response": []
				},
				{
					"name": "Метод импорта пакета медицинской информации",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Валидный бандл должен отработать со статусом 202\", function () {\r",
									"    pm.response.to.have.status(202);\r",
									"});\r",
									"\r",
									"var jsonData = pm.response.json();\r",
									"let bundleId = jsonData.parameter.find(obj => obj.name === \"ResourceId\").valueString;\r",
									"let statusReference = jsonData.parameter.find(obj => obj.name === \"OperationStatusReference\");\r",
									"\r",
									"console.log(statusReference.valueReference.reference);\r",
									"\r",
									"pm.collectionVariables.set(\"bundleId\", bundleId);\r",
									"pm.collectionVariables.set(\"StatusUrl\", statusReference.valueReference.reference);\r",
									""
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						},
						{
							"listen": "prerequest",
							"script": {
								"exec": [
									""
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"request": {
						"method": "POST",
						"header": [
							{
								"key": "X-Fhir-By-Version",
								"value": "active",
								"type": "text"
							}
						],
						"body": {
							"mode": "raw",
							"raw": "{\r\n    \"resourceType\": \"Bundle\",\r\n    \"id\": \"BundlePhysioTest\",\r\n    \"meta\": {\r\n        \"profile\": [\r\n            \"https://fhir.by/AbstractArea/StructureDefinition/Bundle/MedicationDocument\"\r\n        ]\r\n    },\r\n    \"identifier\": {\r\n        \"system\": \"urn:ietf:rfc:3986\",\r\n        \"value\": \"{{$guid}}\"\r\n    },\r\n    \"type\": \"document\",\r\n    \"timestamp\": \"{{$isoTimestamp}}\",\r\n    \"entry\": [\r\n        {\r\n            \"fullUrl\": \"Composition/CompositionPhysioTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"Composition\",\r\n                \"id\": \"CompositionPhysioTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/CompDocument\"\r\n                    ]\r\n                },\r\n                \"status\": \"final\",\r\n                \"type\": {\r\n                    \"coding\": [\r\n                        {\r\n                            \"system\": \"https://fhir.by/ValueSet/CompositionType\",\r\n                            \"code\": \"general\",\r\n                            \"display\": \"Общая медицинская информация\"\r\n                        }\r\n                    ]\r\n                },\r\n                \"subject\": [\r\n                    {\r\n                        \"reference\": \"Patient/PatientTest\"\r\n                    }\r\n                ],\r\n                \"date\": \"2025-12-10\",\r\n                \"author\": [\r\n                    {\r\n                        \"reference\": \"Practitioner/{{PractitionerId}}\"\r\n                    }\r\n                ],\r\n                \"title\": \"CompDocument для наполненного Bundle по физиотерапии\",\r\n                \"custodian\": {\r\n                    \"reference\": \"Organization/{{OrganizationId}}\"\r\n                },\r\n                \"event\": [\r\n                    {\r\n                        \"detail\": [\r\n                            {\r\n                                \"reference\": {\r\n                                    \"reference\": \"Condition/DiagnosisKneeFractureTest\"\r\n                                }\r\n                            }\r\n                        ]\r\n                    },\r\n                    {\r\n                        \"detail\": [\r\n                            {\r\n                                \"reference\": {\r\n                                    \"reference\": \"ServiceRequest/ExampleRequestPhysiotherapyMagnitTest\"\r\n                                }\r\n                            }\r\n                        ]\r\n                    },\r\n                    {\r\n                        \"detail\": [\r\n                            {\r\n                                \"reference\": {\r\n                                    \"reference\": \"ServiceRequest/ExampleRequestPhysiotherapyMassageTest\"\r\n                                }\r\n                            }\r\n                        ]\r\n                    },\r\n                    {\r\n                        \"detail\": [\r\n                            {\r\n                                \"reference\": {\r\n                                    \"reference\": \"Encounter/EncounterPhysioTest\"\r\n                                }\r\n                            }\r\n                        ]\r\n                    }\r\n                ]\r\n            }\r\n        },\r\n        {\r\n            \"fullUrl\": \"Patient/PatientTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"Patient\",\r\n                \"id\": \"PatientTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/PatientWithIdentificationNumber\"\r\n                    ]\r\n                },\r\n                \"name\": [\r\n                    {\r\n                        \"family\": \"Иванов\",\r\n                        \"given\": [\r\n                            \"Петр\",\r\n                            \"Сидорович\"\r\n                        ]\r\n                    }\r\n                ],\r\n                \"identifier\": [\r\n                    {\r\n                        \"type\": {\r\n                            \"coding\": [\r\n                                {\r\n                                    \"system\": \"https://fhir.by/ValueSet/PersonalDocumentType\",\r\n                                    \"code\": \"INP\"\r\n                                }\r\n                            ]\r\n                        },\r\n                        \"value\": \"7551355A009PB4\"\r\n                    },\r\n                    {\r\n                        \"extension\": [\r\n                            {\r\n                                \"extension\": [\r\n                                    {\r\n                                        \"url\": \"https://fhir.by/StructureDefinition/PassportIssuedString\",\r\n                                        \"valueString\": \"Центральным РУВД г Минска, 21.08.2021\"\r\n                                    },\r\n                                    {\r\n                                        \"url\": \"https://fhir.by/StructureDefinition/PassportIssuedDate\",\r\n                                        \"valueDate\": \"2022-08-21\"\r\n                                    },\r\n                                    {\r\n                                        \"url\": \"https://fhir.by/StructureDefinition/PassportIssuedCode\",\r\n                                        \"valueCodeableConcept\": {\r\n                                            \"coding\": [\r\n                                                {\r\n                                                    \"system\": \"https://fhir.by/ValueSet/OCAM\",\r\n                                                    \"version\": \"1.3\",\r\n                                                    \"code\": \"Minsk\",\r\n                                                    \"display\": \"Минск\"\r\n                                                }\r\n                                            ]\r\n                                        }\r\n                                    }\r\n                                ],\r\n                                \"url\": \"https://fhir.by/StructureDefinition/PassportIssued\"\r\n                            }\r\n                        ],\r\n                        \"type\": {\r\n                            \"coding\": [\r\n                                {\r\n                                    \"system\": \"https://fhir.by/ValueSet/PersonalDocumentType\",\r\n                                    \"version\": \"1.10\",\r\n                                    \"code\": \"Passport-RB\",\r\n                                    \"display\": \"Паспорт гражданина Республики Беларусь\"\r\n                                }\r\n                            ]\r\n                        },\r\n                        \"value\": \"MP1253212\"\r\n                    }\r\n                ],\r\n                \"active\": true,\r\n                \"telecom\": [\r\n                    {\r\n                        \"system\": \"phone\",\r\n                        \"value\": \"+375123456789\"\r\n                    }\r\n                ],\r\n                \"gender\": \"male\",\r\n                \"birthDate\": \"1990-12-31\",\r\n                \"deceasedBoolean\": false,\r\n                \"address\": [\r\n                    {\r\n                        \"extension\": [\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/CoutryForAddresses\",\r\n                                \"valueCodeableConcept\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/CitizenshipCode\",\r\n                                            \"version\": \"1.51\",\r\n                                            \"code\": \"BY\",\r\n                                            \"display\": \"Беларусь\"\r\n                                        }\r\n                                    ]\r\n                                }\r\n                            },\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/StreetGeoRegistry\",\r\n                                \"valueCodeableConcept\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/StreetGeoRegistry\",\r\n                                            \"version\": \"1.3\",\r\n                                            \"code\": \"517030229743858774\",\r\n                                            \"display\": \"Минск, г. Минск, Улица Уручская, д. 23 к.2\"\r\n                                        }\r\n                                    ]\r\n                                }\r\n                            },\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/ApartmentRoom\",\r\n                                \"valueString\": \"кв. 101\"\r\n                            }\r\n                        ],\r\n                        \"use\": \"home\",\r\n                        \"text\": \"г. Минск, Улица Уручская\"\r\n                    },\r\n                    {\r\n                        \"extension\": [\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/CoutryForAddresses\",\r\n                                \"valueCodeableConcept\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/CitizenshipCode\",\r\n                                            \"version\": \"1.51\",\r\n                                            \"code\": \"BY\",\r\n                                            \"display\": \"Беларусь\"\r\n                                        }\r\n                                    ]\r\n                                }\r\n                            },\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/StreetGeoRegistry\",\r\n                                \"valueCodeableConcept\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/StreetGeoRegistry\",\r\n                                            \"version\": \"1.3\",\r\n                                            \"code\": \"517030229743858774\",\r\n                                            \"display\": \"Минск, г. Минск, Улица Уручская, д. 23 к.1201\"\r\n                                        }\r\n                                    ]\r\n                                }\r\n                            },\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/ApartmentRoom\",\r\n                                \"valueString\": \"кв. 1201\"\r\n                            }\r\n                        ],\r\n                        \"use\": \"temp\",\r\n                        \"text\": \"г. Минск, Улица Уручская\"\r\n                    }\r\n                ]\r\n            }\r\n        },\r\n        {\r\n            \"fullUrl\": \"Encounter/EncounterPhysioTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"Encounter\",\r\n                \"id\": \"EncounterPhysioTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/EncounterGeneral\"\r\n                    ]\r\n                },\r\n                \"status\": \"completed\",\r\n                \"class\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/VSTermsOfService\",\r\n                                \"code\": \"1\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ],\r\n                \"priority\": {\r\n                    \"coding\": [\r\n                        {\r\n                            \"system\": \"https://fhir.by/ValueSet/HealthCareForms\",\r\n                            \"code\": \"planned\"\r\n                        }\r\n                    ]\r\n                },\r\n                \"type\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/TypeOfHealthCare\",\r\n                                \"code\": \"primary\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ],\r\n                \"subject\": {\r\n                    \"reference\": \"Patient/PatientTest\"\r\n                },\r\n                \"serviceProvider\": {\r\n                    \"reference\": \"Organization/{{OrganizationId}}\"\r\n                },\r\n                \"participant\": [\r\n                    {\r\n                        \"actor\": {\r\n                            \"reference\": \"PractitionerRole/{{PractitionerRole}}\"\r\n                        }\r\n                    }\r\n                ],\r\n                \"actualPeriod\": {\r\n                    \"start\": \"2025-12-10T12:00:00Z\",\r\n                    \"end\": \"2025-12-10T12:30:00Z\"\r\n                },\r\n                \"diagnosis\": [\r\n                    {\r\n                        \"condition\": [\r\n                            {\r\n                                \"reference\": {\r\n                                    \"reference\": \"Condition/DiagnosisKneeFractureTest\"\r\n                                }\r\n                            }\r\n                        ],\r\n                        \"use\": [\r\n                            {\r\n                                \"coding\": [\r\n                                    {\r\n                                        \"system\": \"https://fhir.by/ValueSet/TypeOfDiagnosis\",\r\n                                        \"code\": \"mainDiagnosis\"\r\n                                    }\r\n                                ]\r\n                            }\r\n                        ]\r\n                    }\r\n                ]\r\n            }\r\n        },\r\n        {\r\n            \"fullUrl\": \"Condition/DiagnosisKneeFractureTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"Condition\",\r\n                \"id\": \"DiagnosisKneeFractureTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/FinalDiagnosis\"\r\n                    ]\r\n                },\r\n                \"extension\": [\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/KindOfDiagnosis\",\r\n                        \"valueCodeableConcept\": {\r\n                            \"coding\": [\r\n                                {\r\n                                    \"system\": \"https://fhir.by/ValueSet/KindOfDiagnosisCode\",\r\n                                    \"code\": \"Final\"\r\n                                }\r\n                            ]\r\n                        }\r\n                    },\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/AssertedDate\",\r\n                        \"valueDateTime\": \"2025-12-10\"\r\n                    }\r\n                ],\r\n                \"clinicalStatus\": {\r\n                    \"coding\": [\r\n                        {\r\n                            \"system\": \"http://terminology.hl7.org/CodeSystem/condition-clinical\",\r\n                            \"code\": \"active\"\r\n                        }\r\n                    ]\r\n                },\r\n                \"code\": {\r\n                    \"coding\": [\r\n                        {\r\n                            \"system\": \"https://fhir.by/ValueSet/InternClassificDiseases10\",\r\n                            \"code\": \"S52.40\",\r\n                            \"display\": \"S52.40 - Сочетанный перелом диафизов локтевой и лучевой костей закрытый\"\r\n                        }\r\n                    ],\r\n                    \"text\": \"Сочетанный перелом диафизов левой локтевой и лучевой костей закрытый\"\r\n                },\r\n                \"subject\": {\r\n                    \"reference\": \"Patient/PatientTest\"\r\n                },\r\n                \"onsetDateTime\": \"2025-12-10\",\r\n                \"recordedDate\": \"2025-12-10\",\r\n                \"participant\": [\r\n                    {\r\n                        \"actor\": {\r\n                            \"reference\": \"PractitionerRole/{{PractitionerRole}}\"\r\n                        }\r\n                    }\r\n                ]\r\n            }\r\n        },\r\n        {\r\n            \"fullUrl\": \"ServiceRequest/ExampleRequestPhysiotherapyMagnitTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"ServiceRequest\",\r\n                \"id\": \"ExampleRequestPhysiotherapyMagnitTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/ServiceRequestPhysiotherapy\"\r\n                    ]\r\n                },\r\n                \"extension\": [\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/SpecialtyCode\",\r\n                        \"valueCodeableConcept\": {\r\n                            \"coding\": [\r\n                                {\r\n                                    \"system\": \"https://fhir.by/ValueSet/ServiceSpecialtyBy\",\r\n                                    \"code\": \"C058\",\r\n                                    \"display\": \"Физиотерапия\"\r\n                                }\r\n                            ]\r\n                        }\r\n                    },\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/RequestFromOrganization\",\r\n                        \"valueReference\": {\r\n                            \"reference\": \"Organization/{{OrganizationId}}\"\r\n                        }\r\n                    },\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/ProcedureNumber\",\r\n                        \"valueUnsignedInt\": 5\r\n                    }\r\n                ],\r\n                \"identifier\": [\r\n                    {\r\n                        \"value\": \"2567\"\r\n                    }\r\n                ],\r\n                \"status\": \"active\",\r\n                \"intent\": \"directive\",\r\n                \"category\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/HealthcareServiceCategory\",\r\n                                \"code\": \"02/1\",\r\n                                \"display\": \"Амбулаторно-поликлиническая помощь взрослому населению\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ],\r\n                \"priority\": \"routine\",\r\n                \"code\": {\r\n                    \"concept\": {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/VSPhysioHealthcareService\",\r\n                                \"code\": \"A17-30-025\",\r\n                                \"display\": \"Общая магнитотерапия\"\r\n                            }\r\n                        ]\r\n                    }\r\n                },\r\n                \"orderDetail\": [\r\n                    {\r\n                        \"parameter\": [\r\n                            {\r\n                                \"code\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/PhysicalParameters\",\r\n                                            \"code\": \"frequency\",\r\n                                            \"display\": \"Частота\"\r\n                                        }\r\n                                    ]\r\n                                },\r\n                                \"valueQuantity\": {\r\n                                    \"value\": 5,\r\n                                    \"unit\": \"Гц\",\r\n                                    \"system\": \"https://fhir.by/ValueSet/VSUnitsPhysiother\",\r\n                                    \"code\": \"Hz\"\r\n                                }\r\n                            },\r\n                            {\r\n                                \"code\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/PhysicalParameters\",\r\n                                            \"code\": \"magnetic_induction\",\r\n                                            \"display\": \"Магнитная индукция\"\r\n                                        }\r\n                                    ]\r\n                                },\r\n                                \"valueQuantity\": {\r\n                                    \"value\": 100,\r\n                                    \"comparator\": \"<\",\r\n                                    \"unit\": \"мТл\",\r\n                                    \"system\": \"https://fhir.by/ValueSet/VSUnitsPhysiother\",\r\n                                    \"code\": \"mT\"\r\n                                }\r\n                            }\r\n                        ]\r\n                    }\r\n                ],\r\n                \"quantityQuantity\": {\r\n                    \"value\": 20,\r\n                    \"unit\": \"минуты\",\r\n                    \"system\": \"https://fhir.by/ValueSet/TimeSlots\",\r\n                    \"code\": \"min\"\r\n                },\r\n                \"subject\": {\r\n                    \"reference\": \"Patient/PatientTest\"\r\n                },\r\n                \"encounter\": {\r\n                    \"reference\": \"Encounter/EncounterPhysioTest\"\r\n                },\r\n                \"authoredOn\": \"2025-12-10T12:20:00Z\",\r\n                \"requester\": {\r\n                    \"reference\": \"PractitionerRole/{{PractitionerRole}}\"\r\n                },\r\n                \"performer\": [\r\n                    {\r\n                        \"reference\": \"Organization/{{OrganizationId}}\"\r\n                    }\r\n                ],\r\n                \"location\": [\r\n                    {\r\n                        \"reference\": {\r\n                            \"reference\": \"Location/{{LocationId}}\"\r\n                        }\r\n                    }\r\n                ],\r\n                \"reason\": [\r\n                    {\r\n                        \"reference\": {\r\n                            \"reference\": \"Condition/DiagnosisKneeFractureTest\"\r\n                        }\r\n                    }\r\n                ],\r\n                \"bodySite\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/AnatomicalTerminology\",\r\n                                \"code\": \"Forearm-L\",\r\n                                \"display\": \"Предплечье (лев.)\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ]\r\n            }\r\n        },\r\n        {\r\n            \"fullUrl\": \"ServiceRequest/ExampleRequestPhysiotherapyMassageTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"ServiceRequest\",\r\n                \"id\": \"ExampleRequestPhysiotherapyMassageTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/ServiceRequestPhysiotherapy\"\r\n                    ]\r\n                },\r\n                \"extension\": [\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/SpecialtyCode\",\r\n                        \"valueCodeableConcept\": {\r\n                            \"coding\": [\r\n                                {\r\n                                    \"system\": \"https://fhir.by/ValueSet/ServiceSpecialtyBy\",\r\n                                    \"code\": \"C058\",\r\n                                    \"display\": \"Физиотерапия\"\r\n                                }\r\n                            ]\r\n                        }\r\n                    },\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/RequestFromOrganization\",\r\n                        \"valueReference\": {\r\n                            \"reference\": \"Organization/{{OrganizationId}}\"\r\n                        }\r\n                    },\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/ProcedureNumber\",\r\n                        \"valueUnsignedInt\": 10\r\n                    }\r\n                ],\r\n                \"identifier\": [\r\n                    {\r\n                        \"value\": \"251\"\r\n                    }\r\n                ],\r\n                \"status\": \"active\",\r\n                \"intent\": \"directive\",\r\n                \"category\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/HealthcareServiceCategory\",\r\n                                \"code\": \"02/1\",\r\n                                \"display\": \"Амбулаторно-поликлиническая помощь взрослому населению\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ],\r\n                \"priority\": \"routine\",\r\n                \"code\": {\r\n                    \"concept\": {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/VSPhysioHealthcareService\",\r\n                                \"code\": \"A21-01-004\",\r\n                                \"display\": \"Массаж верхней конечности медицинский\"\r\n                            }\r\n                        ]\r\n                    }\r\n                },\r\n                \"quantityQuantity\": {\r\n                    \"value\": 40,\r\n                    \"unit\": \"минуты\",\r\n                    \"system\": \"https://fhir.by/ValueSet/TimeSlots\",\r\n                    \"code\": \"min\"\r\n                },\r\n                \"subject\": {\r\n                    \"reference\": \"Patient/PatientTest\"\r\n                },\r\n                \"encounter\": {\r\n                    \"reference\": \"Encounter/EncounterPhysioTest\"\r\n                },\r\n                \"authoredOn\": \"2025-12-10T12:20:00Z\",\r\n                \"requester\": {\r\n                    \"reference\": \"PractitionerRole/{{PractitionerRole}}\"\r\n                },\r\n                \"performer\": [\r\n                    {\r\n                        \"reference\": \"Organization/{{OrganizationId}}\"\r\n                    }\r\n                ],\r\n                \"location\": [\r\n                    {\r\n                        \"reference\": {\r\n                            \"reference\": \"Location/{{LocationId}}\"\r\n                        }\r\n                    }\r\n                ],\r\n                \"reason\": [\r\n                    {\r\n                        \"reference\": {\r\n                            \"reference\": \"Condition/DiagnosisKneeFractureTest\"\r\n                        }\r\n                    }\r\n                ],\r\n                \"bodySite\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/AnatomicalTerminology\",\r\n                                \"code\": \"Upper-limb-L\",\r\n                                \"display\": \"Верхняя конечность (лев.)\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ]\r\n            }\r\n        }\r\n    ]\r\n}",
							"options": {
								"raw": {
									"language": "json"
								}
							}
						},
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Bundle/$import",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Bundle",
								"$import"
							]
						}
					},
					"response": []
				},
				{
					"name": "Метод получения статуса импорта пакета медицинской информации",
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Bundle/{{bundleId}}/$status",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Bundle",
								"{{bundleId}}",
								"$status"
							]
						}
					},
					"response": []
				},
				{
					"name": "Метод проверки наличия Направления на физиотерапию",
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Patient/{{patientId}}/ServiceRequest?_profile=https://fhir.by/StructureDefinition/ServiceRequestPhysiotherapy&patient={{patientId}}&_sort=-_lastUpdated",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Patient",
								"{{patientId}}",
								"ServiceRequest"
							],
							"query": [
								{
									"key": "_profile",
									"value": "https://fhir.by/StructureDefinition/ServiceRequestPhysiotherapy"
								},
								{
									"key": "patient",
									"value": "{{patientId}}"
								},
								{
									"key": "_sort",
									"value": "-_lastUpdated"
								}
							]
						}
					},
					"response": []
				},
				{
					"name": "Получение сводной информации о пациенте",
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Patient/{{patientId}}/$everything?start=2025-10&end=2025-12",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Patient",
								"{{patientId}}",
								"$everything"
							],
							"query": [
								{
									"key": "start",
									"value": "2025-10"
								},
								{
									"key": "end",
									"value": "2025-12"
								}
							]
						}
					},
					"response": []
				}
			]
		},
		{
			"name": "2. Результат прохождения физиотерапии",
			"item": [
				{
					"name": "Поиск пациента по идентификатору (patientId)",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"var jsonData = pm.response.json();\r",
									"let patientId = jsonData.entry.find(obj => obj.resource.resourceType === \"Patient\").resource.id;\r",
									"\r",
									"pm.environment.set(\"patientId\", patientId);\r",
									"console.log(patientId)\r",
									""
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Patient?identifier=7551355A009PB4",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Patient"
							],
							"query": [
								{
									"key": "identifier",
									"value": "7551355A009PB4"
								}
							]
						}
					},
					"response": []
				},
				{
					"name": "Метод проверки наличия Направления на магнитотерапию (ServiceRequestMagnit)",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"var jsonData = pm.response.json();\r",
									"let serviceRequestId = jsonData.entry.find(obj => obj.resource.resourceType === \"ServiceRequest\").resource.id;\r",
									"\r",
									"pm.environment.set(\"ServiceRequestMagnit\", serviceRequestId);\r",
									"console.log(serviceRequestId)"
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Patient/{{patientId}}/ServiceRequest?_profile=https://fhir.by/StructureDefinition/ServiceRequestPhysiotherapy&patient={{patientId}}&_sort=-_lastUpdated&code-concept=A17-30-025",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Patient",
								"{{patientId}}",
								"ServiceRequest"
							],
							"query": [
								{
									"key": "_profile",
									"value": "https://fhir.by/StructureDefinition/ServiceRequestPhysiotherapy"
								},
								{
									"key": "patient",
									"value": "{{patientId}}"
								},
								{
									"key": "_sort",
									"value": "-_lastUpdated"
								},
								{
									"key": "code-concept",
									"value": "A17-30-025"
								}
							]
						}
					},
					"response": []
				},
				{
					"name": "Метод проверки наличия Направления на Массаж (ServiceRequestMassage)",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"var jsonData = pm.response.json();\r",
									"let serviceRequestId = jsonData.entry.find(obj => obj.resource.resourceType === \"ServiceRequest\").resource.id;\r",
									"\r",
									"pm.environment.set(\"ServiceRequestMassage\", serviceRequestId);\r",
									"console.log(serviceRequestId)"
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Patient/{{patientId}}/ServiceRequest?_profile=https://fhir.by/StructureDefinition/ServiceRequestPhysiotherapy&patient={{patientId}}&_sort=-_lastUpdated&code-concept=A21-01-004",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Patient",
								"{{patientId}}",
								"ServiceRequest"
							],
							"query": [
								{
									"key": "_profile",
									"value": "https://fhir.by/StructureDefinition/ServiceRequestPhysiotherapy"
								},
								{
									"key": "patient",
									"value": "{{patientId}}"
								},
								{
									"key": "_sort",
									"value": "-_lastUpdated"
								},
								{
									"key": "code-concept",
									"value": "A21-01-004"
								}
							]
						}
					},
					"response": []
				},
				{
					"name": "Метод поиска диагноза (ConditionId)",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"var jsonData = pm.response.json();\r",
									"let conditionId = jsonData.entry.find(obj => obj.resource.resourceType === \"Condition\").resource.id;\r",
									"\r",
									"pm.environment.set(\"ConditionId\", conditionId);\r",
									"console.log(conditionId)"
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Patient/{{patientId}}/Condition?_profile=https://fhir.by/StructureDefinition/FinalDiagnosis&patient={{patientId}}&_sort=-_lastUpdated",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Patient",
								"{{patientId}}",
								"Condition"
							],
							"query": [
								{
									"key": "_profile",
									"value": "https://fhir.by/StructureDefinition/FinalDiagnosis"
								},
								{
									"key": "patient",
									"value": "{{patientId}}"
								},
								{
									"key": "_sort",
									"value": "-_lastUpdated"
								}
							]
						}
					},
					"response": []
				},
				{
					"name": "Метод импорта пакета медицинской информации",
					"event": [
						{
							"listen": "test",
							"script": {
								"exec": [
									"pm.test(\"Валидный бандл должен отработать со статусом 202\", function () {\r",
									"    pm.response.to.have.status(202);\r",
									"});\r",
									"\r",
									"var jsonData = pm.response.json();\r",
									"let bundleId = jsonData.parameter.find(obj => obj.name === \"ResourceId\").valueString;\r",
									"let statusReference = jsonData.parameter.find(obj => obj.name === \"OperationStatusReference\");\r",
									"\r",
									"console.log(statusReference.valueReference.reference);\r",
									"\r",
									"pm.collectionVariables.set(\"bundleId\", bundleId);\r",
									"pm.collectionVariables.set(\"StatusUrl\", statusReference.valueReference.reference);\r",
									""
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						},
						{
							"listen": "prerequest",
							"script": {
								"exec": [
									""
								],
								"type": "text/javascript",
								"packages": {},
								"requests": {}
							}
						}
					],
					"request": {
						"method": "POST",
						"header": [
							{
								"key": "X-Fhir-By-Version",
								"value": "active",
								"type": "text"
							}
						],
						"body": {
							"mode": "raw",
							"raw": "{\r\n    \"resourceType\": \"Bundle\",\r\n    \"id\": \"BundlePhysioProcedureTest\",\r\n    \"meta\": {\r\n        \"profile\": [\r\n            \"https://fhir.by/AbstractArea/StructureDefinition/Bundle/MedicationDocument\"\r\n        ]\r\n    },\r\n    \"identifier\": {\r\n        \"system\": \"urn:ietf:rfc:3986\",\r\n        \"value\": \"{{$guid}}\"\r\n    },\r\n    \"type\": \"document\",\r\n    \"timestamp\": \"{{$isoTimestamp}}\",\r\n    \"entry\": [\r\n        {\r\n            \"fullUrl\": \"Composition/CompositionPhysioProcedureTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"Composition\",\r\n                \"id\": \"CompositionPhysioProcedureTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/CompDocument\"\r\n                    ]\r\n                },\r\n                \"status\": \"final\",\r\n                \"type\": {\r\n                    \"coding\": [\r\n                        {\r\n                            \"system\": \"https://fhir.by/ValueSet/CompositionType\",\r\n                            \"code\": \"general\",\r\n                            \"display\": \"Общая медицинская информация\"\r\n                        }\r\n                    ]\r\n                },\r\n                \"subject\": [\r\n                    {\r\n                        \"reference\": \"Patient/PatientTest\"\r\n                    }\r\n                ],\r\n                \"date\": \"2025-12-12\",\r\n                \"author\": [\r\n                    {\r\n                        \"reference\": \"Practitioner/{{PractitionerId}}\"\r\n                    }\r\n                ],\r\n                \"title\": \"CompDocument для наполненного Bundle по физиотерапии\",\r\n                \"custodian\": {\r\n                    \"reference\": \"Organization/{{OrganizationId}}\"\r\n                },\r\n                \"event\": [\r\n                    {\r\n                        \"detail\": [\r\n                            {\r\n                                \"reference\": {\r\n                                    \"reference\": \"Procedure/ExamplePhysiotherapyProcedureMagnitTest\"\r\n                                }\r\n                            }\r\n                        ]\r\n                    },\r\n                    {\r\n                        \"detail\": [\r\n                            {\r\n                                \"reference\": {\r\n                                    \"reference\": \"Procedure/ExamplePhysiotherapyProcedureMassageTest\"\r\n                                }\r\n                            }\r\n                        ]\r\n                    }\r\n                ]\r\n            }\r\n        },\r\n        {\r\n            \"fullUrl\": \"Patient/PatientTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"Patient\",\r\n                \"id\": \"PatientTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/PatientWithIdentificationNumber\"\r\n                    ]\r\n                },\r\n                \"name\": [\r\n                    {\r\n                        \"family\": \"Иванов\",\r\n                        \"given\": [\r\n                            \"Петр\",\r\n                            \"Сидорович\"\r\n                        ]\r\n                    }\r\n                ],\r\n                \"identifier\": [\r\n                    {\r\n                        \"type\": {\r\n                            \"coding\": [\r\n                                {\r\n                                    \"system\": \"https://fhir.by/ValueSet/PersonalDocumentType\",\r\n                                    \"code\": \"INP\"\r\n                                }\r\n                            ]\r\n                        },\r\n                        \"value\": \"7551355A009PB4\"\r\n                    },\r\n                    {\r\n                        \"extension\": [\r\n                            {\r\n                                \"extension\": [\r\n                                    {\r\n                                        \"url\": \"https://fhir.by/StructureDefinition/PassportIssuedString\",\r\n                                        \"valueString\": \"Центральным РУВД г Минска, 21.08.2021\"\r\n                                    },\r\n                                    {\r\n                                        \"url\": \"https://fhir.by/StructureDefinition/PassportIssuedDate\",\r\n                                        \"valueDate\": \"2022-08-21\"\r\n                                    },\r\n                                    {\r\n                                        \"url\": \"https://fhir.by/StructureDefinition/PassportIssuedCode\",\r\n                                        \"valueCodeableConcept\": {\r\n                                            \"coding\": [\r\n                                                {\r\n                                                    \"system\": \"https://fhir.by/ValueSet/OCAM\",\r\n                                                    \"version\": \"1.3\",\r\n                                                    \"code\": \"Minsk\",\r\n                                                    \"display\": \"Минск\"\r\n                                                }\r\n                                            ]\r\n                                        }\r\n                                    }\r\n                                ],\r\n                                \"url\": \"https://fhir.by/StructureDefinition/PassportIssued\"\r\n                            }\r\n                        ],\r\n                        \"type\": {\r\n                            \"coding\": [\r\n                                {\r\n                                    \"system\": \"https://fhir.by/ValueSet/PersonalDocumentType\",\r\n                                    \"version\": \"1.10\",\r\n                                    \"code\": \"Passport-RB\",\r\n                                    \"display\": \"Паспорт гражданина Республики Беларусь\"\r\n                                }\r\n                            ]\r\n                        },\r\n                        \"value\": \"MP1253212\"\r\n                    }\r\n                ],\r\n                \"active\": true,\r\n                \"telecom\": [\r\n                    {\r\n                        \"system\": \"phone\",\r\n                        \"value\": \"+375123456789\"\r\n                    }\r\n                ],\r\n                \"gender\": \"male\",\r\n                \"birthDate\": \"1990-12-31\",\r\n                \"deceasedBoolean\": false,\r\n                \"address\": [\r\n                    {\r\n                        \"extension\": [\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/CoutryForAddresses\",\r\n                                \"valueCodeableConcept\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/CitizenshipCode\",\r\n                                            \"version\": \"1.51\",\r\n                                            \"code\": \"BY\",\r\n                                            \"display\": \"Беларусь\"\r\n                                        }\r\n                                    ]\r\n                                }\r\n                            },\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/StreetGeoRegistry\",\r\n                                \"valueCodeableConcept\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/StreetGeoRegistry\",\r\n                                            \"version\": \"1.3\",\r\n                                            \"code\": \"517030229743858774\",\r\n                                            \"display\": \"Минск, г. Минск, Улица Уручская, д. 23 к.2\"\r\n                                        }\r\n                                    ]\r\n                                }\r\n                            },\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/ApartmentRoom\",\r\n                                \"valueString\": \"кв. 101\"\r\n                            }\r\n                        ],\r\n                        \"use\": \"home\",\r\n                        \"text\": \"г. Минск, Улица Уручская\"\r\n                    },\r\n                    {\r\n                        \"extension\": [\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/CoutryForAddresses\",\r\n                                \"valueCodeableConcept\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/CitizenshipCode\",\r\n                                            \"version\": \"1.51\",\r\n                                            \"code\": \"BY\",\r\n                                            \"display\": \"Беларусь\"\r\n                                        }\r\n                                    ]\r\n                                }\r\n                            },\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/StreetGeoRegistry\",\r\n                                \"valueCodeableConcept\": {\r\n                                    \"coding\": [\r\n                                        {\r\n                                            \"system\": \"https://fhir.by/ValueSet/StreetGeoRegistry\",\r\n                                            \"version\": \"1.3\",\r\n                                            \"code\": \"517030229743858774\",\r\n                                            \"display\": \"Минск, г. Минск, Улица Уручская, д. 23 к.1201\"\r\n                                        }\r\n                                    ]\r\n                                }\r\n                            },\r\n                            {\r\n                                \"url\": \"https://fhir.by/StructureDefinition/ApartmentRoom\",\r\n                                \"valueString\": \"кв. 1201\"\r\n                            }\r\n                        ],\r\n                        \"use\": \"temp\",\r\n                        \"text\": \"г. Минск, Улица Уручская\"\r\n                    }\r\n                ]\r\n            }\r\n        },\r\n        {\r\n            \"fullUrl\": \"Procedure/ExamplePhysiotherapyProcedureMagnitTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"Procedure\",\r\n                \"id\": \"ExamplePhysiotherapyProcedureMagnitTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/PhysiotherapyProcedure\"\r\n                    ]\r\n                },\r\n                \"extension\": [\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/ProcedureNumber\",\r\n                        \"valueUnsignedInt\": 5\r\n                    }\r\n                ],\r\n                \"basedOn\": [\r\n                    {\r\n                        \"reference\": \"ServiceRequest/{{ServiceRequestMagnit}}\"\r\n                    }\r\n                ],\r\n                \"status\": \"completed\",\r\n                \"category\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/HealthcareServiceCategory\",\r\n                                \"code\": \"02/1\",\r\n                                \"display\": \"Амбулаторно-поликлиническая помощь взрослому населению\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ],\r\n                \"code\": {\r\n                    \"coding\": [\r\n                        {\r\n                            \"system\": \"https://fhir.by/ValueSet/VSPhysioHealthcareService\",\r\n                            \"code\": \"A17-30-025\",\r\n                            \"display\": \"Общая магнитотерапия\"\r\n                        }\r\n                    ]\r\n                },\r\n                \"subject\": {\r\n                    \"reference\": \"Patient/PatientTest\"\r\n                },\r\n                \"occurrencePeriod\": {\r\n                    \"start\": \"2025-12-12T12:20:00Z\",\r\n                    \"end\": \"2025-12-25T12:20:00Z\"\r\n                },\r\n                \"recorded\": \"2025-12-25T12:20:00Z\",\r\n                \"recorder\": {\r\n                    \"reference\": \"PractitionerRole/{{PractitionerRole}}\"\r\n                },\r\n                \"performer\": [\r\n                    {\r\n                        \"actor\": {\r\n                            \"reference\": \"Organization/{{OrganizationId}}\"\r\n                        }\r\n                    }\r\n                ],\r\n                \"location\": {\r\n                    \"reference\": \"Location/{{LocationId}}\"\r\n                },\r\n                \"reason\": [\r\n                    {\r\n                        \"reference\": {\r\n                            \"reference\": \"Condition/{{ConditionId}}\"\r\n                        }\r\n                    }\r\n                ],\r\n                \"bodySite\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/AnatomicalTerminology\",\r\n                                \"code\": \"Forearm-L\",\r\n                                \"display\": \"Предплечье (лев.)\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ],\r\n                \"outcome\": {\r\n                    \"coding\": [\r\n                        {\r\n                            \"system\": \"https://fhir.by/ValueSet/ProcedureResult\",\r\n                            \"code\": \"successful\",\r\n                            \"display\": \"Успешно\"\r\n                        }\r\n                    ]\r\n                },\r\n                \"followUp\": [\r\n                    {\r\n                        \"text\": \"Рекомендуется 20 минут после процедуры не выходить на холод.\"\r\n                    }\r\n                ]\r\n            }\r\n        },\r\n        {\r\n            \"fullUrl\": \"Procedure/ExamplePhysiotherapyProcedureMassageTest\",\r\n            \"resource\": {\r\n                \"resourceType\": \"Procedure\",\r\n                \"id\": \"ExamplePhysiotherapyProcedureMassageTest\",\r\n                \"meta\": {\r\n                    \"profile\": [\r\n                        \"https://fhir.by/StructureDefinition/PhysiotherapyProcedure\"\r\n                    ]\r\n                },\r\n                \"extension\": [\r\n                    {\r\n                        \"url\": \"https://fhir.by/StructureDefinition/ProcedureNumber\",\r\n                        \"valueUnsignedInt\": 2\r\n                    }\r\n                ],\r\n                \"basedOn\": [\r\n                    {\r\n                        \"reference\": \"ServiceRequest/{{ServiceRequestMassage}}\"\r\n                    }\r\n                ],\r\n                \"status\": \"stopped\",\r\n                \"category\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/HealthcareServiceCategory\",\r\n                                \"code\": \"02/1\",\r\n                                \"display\": \"Амбулаторно-поликлиническая помощь взрослому населению\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ],\r\n                \"code\": {\r\n                    \"coding\": [\r\n                        {\r\n                            \"system\": \"https://fhir.by/ValueSet/VSPhysioHealthcareService\",\r\n                            \"code\": \"A21-01-004\",\r\n                            \"display\": \"Массаж верхней конечности медицинский\"\r\n                        }\r\n                    ]\r\n                },\r\n                \"subject\": {\r\n                    \"reference\": \"Patient/PatientTest\"\r\n                },\r\n                \"occurrencePeriod\": {\r\n                    \"start\": \"2025-12-12T12:20:00Z\",\r\n                    \"end\": \"2025-12-15T12:20:00Z\"\r\n                },\r\n                \"recorded\": \"2025-12-15T12:20:00Z\",\r\n                \"recorder\": {\r\n                    \"reference\": \"PractitionerRole/{{PractitionerRole}}\"\r\n                },\r\n                \"performer\": [\r\n                    {\r\n                        \"actor\": {\r\n                            \"reference\": \"Organization/{{OrganizationId}}\"\r\n                        }\r\n                    }\r\n                ],\r\n                \"location\": {\r\n                    \"reference\": \"Location/{{LocationId}}\"\r\n                },\r\n                \"reason\": [\r\n                    {\r\n                        \"reference\": {\r\n                            \"reference\": \"Condition/{{ConditionId}}\"\r\n                        }\r\n                    }\r\n                ],\r\n                \"bodySite\": [\r\n                    {\r\n                        \"coding\": [\r\n                            {\r\n                                \"system\": \"https://fhir.by/ValueSet/AnatomicalTerminology\",\r\n                                \"code\": \"Upper-limb-L\",\r\n                                \"display\": \"Верхняя конечность (лев.)\"\r\n                            }\r\n                        ]\r\n                    }\r\n                ],\r\n                \"outcome\": {\r\n                    \"coding\": [\r\n                        {\r\n                            \"system\": \"https://fhir.by/ValueSet/ProcedureResult\",\r\n                            \"code\": \"partially-successful\",\r\n                            \"display\": \"Частично успешно\"\r\n                        }\r\n                    ]\r\n                },\r\n                \"note\": [\r\n                    {\r\n                        \"text\": \"Процедура остановлена по желанию пациента\"\r\n                    }\r\n                ]\r\n            }\r\n        }\r\n    ]\r\n}",
							"options": {
								"raw": {
									"language": "json"
								}
							}
						},
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Bundle/$import",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Bundle",
								"$import"
							]
						}
					},
					"response": []
				},
				{
					"name": "Метод получения статуса импорта пакета медицинской информации",
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Bundle/{{bundleId}}/$status",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Bundle",
								"{{bundleId}}",
								"$status"
							]
						}
					},
					"response": []
				},
				{
					"name": "Метод проверки наличия Процедуры физиотерапии",
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Patient/{{patientId}}/Procedure?_profile=https://fhir.by/StructureDefinition/PhysiotherapyProcedure&patient={{patientId}}&_sort=-_lastUpdated",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Patient",
								"{{patientId}}",
								"Procedure"
							],
							"query": [
								{
									"key": "_profile",
									"value": "https://fhir.by/StructureDefinition/PhysiotherapyProcedure"
								},
								{
									"key": "patient",
									"value": "{{patientId}}"
								},
								{
									"key": "_sort",
									"value": "-_lastUpdated"
								}
							]
						}
					},
					"response": []
				},
				{
					"name": "Получение сводной информации о пациенте",
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Patient/{{patientId}}/$everything?start=2025-10&end=2025-12",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Patient",
								"{{patientId}}",
								"$everything"
							],
							"query": [
								{
									"key": "start",
									"value": "2025-10"
								},
								{
									"key": "end",
									"value": "2025-12"
								}
							]
						}
					},
					"response": []
				}
			]
		},
		{
			"name": "Отмена импорта медицинской информации",
			"item": [
				{
					"name": "Отмена импорта медицинской информации",
					"request": {
						"method": "POST",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Bundle/{{bundleId}}/$cancel",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Bundle",
								"{{bundleId}}",
								"$cancel"
							]
						}
					},
					"response": []
				},
				{
					"name": "Получение статуса импорта пакета медицинской информации",
					"request": {
						"method": "GET",
						"header": [],
						"url": {
							"raw": "https://pp.cisz.by/api/fhir/Bundle/{{bundleId}}/$status",
							"protocol": "https",
							"host": [
								"pp",
								"cisz",
								"by"
							],
							"path": [
								"api",
								"fhir",
								"Bundle",
								"{{bundleId}}",
								"$status"
							]
						}
					},
					"response": []
				}
			]
		}
	],
	"auth": {
		"type": "oauth2",
		"oauth2": [
			{
				"key": "useBrowser",
				"value": true,
				"type": "boolean"
			},
			{
				"key": "redirect_uri",
				"value": "https://oauth.pstmn.io/v1/callback",
				"type": "string"
			},
			{
				"key": "clientId",
				"value": "mis_agsr_web_application",
				"type": "string"
			},
			{
				"key": "tokenRequestParams",
				"value": [
					{
						"key": "origin",
						"value": "https://oauth.pstmn.io/v1/callback",
						"enabled": true,
						"send_as": "request_header"
					}
				],
				"type": "any"
			},
			{
				"key": "scope",
				"value": "profile email acr realm roles",
				"type": "string"
			},
			{
				"key": "accessTokenUrl",
				"value": "https://pp.cisz.by/auth/api/realms/iehr/token",
				"type": "string"
			},
			{
				"key": "authUrl",
				"value": "https://pp.cisz.by/auth/api/realms/iehr/auth",
				"type": "string"
			},
			{
				"key": "clientSecret",
				"value": "",
				"type": "string"
			},
			{
				"key": "grant_type",
				"value": "authorization_code_with_pkce",
				"type": "string"
			},
			{
				"key": "refreshRequestParams",
				"value": [],
				"type": "any"
			},
			{
				"key": "authRequestParams",
				"value": [],
				"type": "any"
			},
			{
				"key": "challengeAlgorithm",
				"value": "S256",
				"type": "string"
			},
			{
				"key": "addTokenTo",
				"value": "header",
				"type": "string"
			},
			{
				"key": "client_authentication",
				"value": "body",
				"type": "string"
			}
		]
	},
	"event": [
		{
			"listen": "prerequest",
			"script": {
				"type": "text/javascript",
				"packages": {},
				"requests": {},
				"exec": [
					""
				]
			}
		},
		{
			"listen": "test",
			"script": {
				"type": "text/javascript",
				"packages": {},
				"requests": {},
				"exec": [
					""
				]
			}
		}
	],
	"variable": [
		{
			"key": "practitioner_id",
			"value": ""
		},
		{
			"key": "organization_id",
			"value": ""
		},
		{
			"key": "locationId",
			"value": ""
		},
		{
			"key": "patientId",
			"value": ""
		},
		{
			"key": "bundleId",
			"value": ""
		},
		{
			"key": "StatusUrl",
			"value": ""
		}
	]
}